<?php

namespace Home\Controller;

class RulesController extends CommController
{
    public function index($loc = null)
    {
        $platrule = M("platrule");

        $loc != null ? $where["plr_id"] = $loc : null;
        $where["plr_type"] = $this->ic_u_type;
        $where["plr_status"] = 1;
        $info = $platrule->where($where)->find();
        $this->assign("info", $info);
        unset($where["plr_id"]);
        $this->assign("list", $platrule->where($where)->field("plr_id,plr_title")->select());
        $this->display();
    }
}
